package net.jjjshop.supplier.service.statistics;

import com.alibaba.fastjson.JSONObject;
import net.jjjshop.common.param.HomeParam;
import net.jjjshop.common.vo.statistics.ProductHomeRankingVo;
import net.jjjshop.common.vo.statistics.ProductRefundRankingVo;
import net.jjjshop.common.vo.statistics.ProductSaleRankingVo;

import java.util.List;
import java.util.Map;

/**
 * 用户统计数据 服务类
 * @author jjjshop
 * @since 2022-06-28
 */

public interface ProductRankingService {

    /**
     * 获取商品统计数据
     * @param
     * @return
     */
    //获取商品统计数据
    JSONObject getProductData(Integer shopSupplierId);

    /**
     * 按照时间范围获取商品订单数据
     * @param startDate
     * @param endDate
     * @param type
     * @return
     */
    int getOrderProductData(String startDate, String endDate, String type,Integer shopSupplierId);

    /**
     * 获取商品销售榜单
     * @param
     * @return
     */
    List<ProductSaleRankingVo> getSaleRanking(Integer shopSupplierId);

    /**
     * 获取商品退款榜单
     * @param
     * @return
     */
    List<ProductRefundRankingVo> getRefundRanking(Integer shopSupplierId);

    /**
     * 通过时间范围查询商品统计数据
     * @param startDate,endDate
     * @return
     */
    Map<String, Object> getProductDataByDate(String startDate, String endDate, Integer shopSupplierId);

    List<ProductHomeRankingVo> getSaleTimeRanking(HomeParam param);
}
